import {
	defineStore
} from 'pinia';
const useAddressStore = defineStore('address', {
	state: () => ({
		address: uni.getStorageSync('address') || ""
	}),
	actions: {
		setAddress(value) {
			this.address = value;
			uni.setStorageSync('address', value);
		},
		removeAddress() {
			this.address = null;
			uni.removeStorageSync('address');
		}
	}
});

export default useAddressStore;